<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@page import="org.huqiwen.blog.data.CategoryDataBean"%>
<%@ taglib prefix="fck" uri="http://java.fckeditor.net"%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
  <head>
    <title>添加文章</title>
	<link rel="stylesheet" type="text/css" href="../skin/default/css/index.css">
	<link rel="stylesheet" type="text/css" href="../skin/default/css/addBlog.css">
	<script type="text/javascript" src="../js/verify.js"></script>
	<jsp:useBean id="category" class="org.huqiwen.blog.logic.CategoryLogicBean"/>
  </head>
  <% List<CategoryDataBean> list = category.findAllCategory();%>
  <body>
  <div id="container">
  <%@include file="../head.jsp" %>
	  <div id="addblog">
	  <form action="/MyBlogDemo/BlogActionServlet?method=addBlog" method="post" name="blog">
	  <div class="blogTitle">标题：<input type="text" name="blogTitle" id="title"/></div>
	  <fck:editor instanceName="blogContent" value=" " height="400"></fck:editor>
	  <br>
	  分类：<select name="category">
	  			<% for(int i=0;i<list.size();i++){ 
	  				CategoryDataBean bean = (CategoryDataBean)list.get(i);
	  			%>
	  			<option value="<%=bean.getCatId()%>"><%=bean.getCatName()%></option>
	  			<%}%>
	  	   </select>
	  	   <br/>
	  	   <br/>
	  <input type="button" value="发表文章" onclick="addBlogCheck()"/>
	  </form>
	  </div>
	<%@include file="../foot.jsp" %>
  	</div> 
  </body>
</html>
